<?php
/* 
 * Copyright (c) 2018-2021   All rights reserved.
 * 
 * 创建时间：2021-11-02 23:20
 *
 * 项目：rm  -  $  - form.php
 *
 * 作者：liwei 
 */

use modules\levfm\widgets\inputs\inputsFormWidget;
?>


<?php foreach ($inputs as $v) : $v['inputname'] = $v['inputname'] ?: \modules\levfm\table\LevfmForms::tableFieldname($v['id']);?>

<?php if ($formInfo && \modules\levfm\table\LevfmFields::isVoteTmp($v['settings'])):?>
    <?=inputsFormWidget::vote([$v], $values, $pre, $formInfo);?>
<?php endif;?>

    <div class="card-footer formFieldBox field-settingsmodel-<?php echo $v['inputname']?>">
        <div class="item-after"><div class="hint-block"><?php echo inputsFormWidget::replaceKeyword($v['placeholder'])?></div></div>
        <inpt class="item-input">
            <label class="control-label" for="settingsmodel-<?php echo $v['inputname']?>">
                <?php echo \modules\levfm\table\LevfmFields::setBtn($v['id']),$v['title']?>
            </label>
            <?php
            $v['inputvalue'] = isset($values[$v['inputname']]) ? $values[$v['inputname']] : $v['inputvalue'];
            echo inputsFormWidget::run(
                $v['inputtype'],
                inputsFormWidget::getPreInputname($v['inputname'], $pre),
                $v['inputvalue'],
                $v
            );
            ?>
        </inpt>
    </div>
<?php endforeach;?>
